<?php
	class VillalistAction extends BaseAction{
			public function index(){
			$id = $_GET['b_id'];
			$result =M("bieshu")->join("vip ON vip.v_id = bieshu.b_broker")->where("b_id=$id")->join("district ON district.d_id = bieshu.b_district")->select();			
			$v_id = $result['0']['v_id'];
			$b_name = $result['0']['b_name'];

			$rent = M("bieshu")->where("b_broker=$v_id")->limit("15")->field("b_name,b_d_rent,b_id")->select();
			$this->assign("rent",$rent);

			$newtj = M("bieshu")->where("is_jingpin")->order("b_id desc")->limit(15)->field("b_name,b_d_rent,b_id")->select();
			
			$lou = M("bieshu")->where("b_name = '$b_name'")->limit("15")->select();
			$this->assign("lou",$lou);
			$this->assign("result",$result);
			$this->assign("newtj",$newtj);
			//var_dump($newtj);exit;
			$this->display();
		}
		
		
		

	
	}




?>